1. Field of the Invention
This invention relates to pulse width modulation.
2. Prior Art
For information transmission over distances, it is often desirable to encode such information upon a carrier signal. Various types of modulating signals are known. For example, an analog modulated (AM) signal, such as that used in AM radio transmissions, is a carrier signal with a certain frequency, and its amplitude is modulated with the information to be transmitted. If the information to be transmitted is analog, then an analog to AM conversion has to be done. Similarly, if a frequency modulation (FM) is desired, and if the information source is analog, an analog to FM conversion is necessary. When information is received, a decoding process is necessary. Various electronic circuits, including integrated circuits, exist to convert analog information into AM or FM signals, or AM or FM signals into analog information. Often, there is need to encode information by modifying the pulse width of a carrier, called a pulse width modulated (PWM) signal, or to extract information from a PWM signal. To date, there is no easy way to do this.
In automotive applications, for example, the exhaust gas sensor generates a PWM type signal which contains information about oxygen content. The engine controller continuously monitors the rising and falling edges of the PWM, thus using up important hardware and software resources. If the PWM were converted to an analog signal, such resources could be freed and an analog to digital channel used instead, thus resulting in possible cost savings.
Another automotive application where a PWM signal is present is spark advance command encoding. The spark advance command, which is sent to the ignition module by the engine controller, is a PWM signal in some vehicles. Often, while developing new or improved vehicle functionalities, it is desirable to modify the command generated by the engine controller without having to modify the engine controller's software, a time and resource consuming task. One possible solution is to intercept the PWM signal and to modify its pulse width (stretch or compress) based on an analog command. This modified pulse width is then sent to the ignition module.
The automotive examples above show the need for PWM to analog and analog to PWM conversions, which is the subject of the present invention.